<!--
  Generated template for the ForgetPwdPage page.

  See http://ionicframework.com/docs/components/#navigation for more info on
  Ionic pages and navigation.
-->
<ion-header>

  <ion-navbar>
    <ion-title>忘记密码</ion-title>
  </ion-navbar>

</ion-header>


<ion-content>
  <div [hidden]="isHidden">
    <ion-item>
      <ion-label fixed>手机号</ion-label>
      <ion-input type="text" placeholder="请输入手机号" [(ngModel)]="user.mobile"></ion-input>
    </ion-item>
    <ion-item>
      <ion-label fixed>验证码</ion-label>
      <ion-input type="text" placeholder="请输入验证码" [(ngModel)]="user.code"></ion-input>
      <button item-right ion-button color="primary" (click)="getCode()" [disabled]="status">{{codeValue}}</button>
    </ion-item>
    <div padding>
      <button ion-button block color="primary" (click)="next()"
              [disabled]="!(user.code.length > 0 && user.mobile.length > 0)"> 下一步
      </button>
    </div>
  </div>
  <div [hidden]="!isHidden">
    <ion-item>
      <ion-label fixed>新密码</ion-label>
      <ion-input type="password" placeholder="请输入新密码" [(ngModel)]="user.password"></ion-input>
    </ion-item>
    <ion-item>
      <ion-label fixed>确认密码</ion-label>
      <ion-input type="password" placeholder="请确认密码" [(ngModel)]="user.rePassword"></ion-input>
    </ion-item>
    <div padding>
      <button ion-button block color="primary" (click)="changePassword()"
              [disabled]="!(user.password.length > 0 && user.rePassword.length > 0)"> 确认
      </button>
    </div>
  </div>

</ion-content>
